package com.mgg.common.client.message;

import com.mgg.common.vo.ResultVO;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @Author: lijun
 * @Date: 2018/9/17 11:30
 */
@FeignClient(value = "message-server", fallback = MessageClientFallback.class)
public interface MessageClient {
    @RequestMapping(value = "/msg/sms/send", method = RequestMethod.GET)
    public ResultVO<?> sendSms(@RequestParam("sms_type") Integer smsType, @RequestParam("sub_type") Integer subType,
                               @RequestParam("mobile") String mobile, @RequestParam("param") String param);

    @RequestMapping(value = "/msg/ordernotice", method = RequestMethod.GET)
    public ResultVO<?> sendOrderNotice(@RequestParam("user_id") String userId,
                                       @RequestParam("order_id") String orderId);

    @RequestMapping(value = "/msg/paynotice", method = RequestMethod.GET)
    public ResultVO<?> sendPayNotice(@RequestParam("user_id") String userId, @RequestParam("super_id") String superId,
                                     @RequestParam("amount") String amount);

    @RequestMapping(value = "/msg/withdraw", method = RequestMethod.GET)
    public ResultVO<?> sendWithdrawSubmit(@RequestParam("user_id") String userId);

    @RequestMapping(value = "/msg/withdrawfail", method = RequestMethod.GET)
    public ResultVO<?> sendWithdrawFail(@RequestParam("user_id") String userId, @RequestParam("date") String date,
                                        @RequestParam("reason") String reason);

    @RequestMapping(value = "/msg/swithdrawsuc", method = RequestMethod.GET)
    public ResultVO<?> sendWithdrawSuccess(@RequestParam("user_id") String userId, @RequestParam("date") String date);

    @RequestMapping(value = "/msg/shopkeeper", method = RequestMethod.GET)
    public ResultVO<?> sendRegistShopkeeperNotice(@RequestParam("user_id") String userId, @RequestParam("rname") String name);

    @RequestMapping(value = "/msg/newshopkeeper", method = RequestMethod.GET)
    public ResultVO<?> sendNewShopkeeperNotice(@RequestParam("user_id") String userId,
                                               @RequestParam("mobile") String mobile, @RequestParam("name") String name,
                                               @RequestParam("phone") String phone);

    @RequestMapping(value = "/msg/teamshopkeeper", method = RequestMethod.GET)
    public ResultVO<?> sendTeamShopkeeperNotice(@RequestParam("user_id") String userId,
                                                @RequestParam("mobile") String mobile, @RequestParam("shopkeeper") String shopkeeper,
                                                @RequestParam("name") String name, @RequestParam("phone") String phone);

    @RequestMapping(value = "/msg/actcode", method = RequestMethod.GET)
    public ResultVO<?> sendShopActCode(@RequestParam("user_id") String userId, @RequestParam("code") String code,
                                       @RequestParam("page") String page);

    @RequestMapping(value = "/msg/cardcode", method = RequestMethod.GET)
    public ResultVO<?> sendQQSServerCardCode(@RequestParam("user_id") String userId,
                                             @RequestParam("code1") String code1, @RequestParam("code2") String code2,
                                             @RequestParam("code3") String code3, @RequestParam("code4") String code4);
}
